
import { observable, computed, action } from 'mobx'
import { createContext } from 'react';
import ChildrenPageUtils from "@/store/extends";
import { uSelectDevStatusAndSimpleData } from '@/api/setting';

class Serverinfo extends ChildrenPageUtils {
  @observable pageData: Setting.DevBaseInfo | null = null
  @action.bound
  async updatePageDataSource() {
    let res = await uSelectDevStatusAndSimpleData({
      devId: this.pageQuery.devId
    }).catch(err => {})
    if (res) {
      this.pageData = res.data
    }
  }
}
export const serverInfoStore = createContext(new Serverinfo())
